<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Vue3.0</title>
    <script src="https://unpkg.com/vue@next"></script>
    <style>
        .demo {
            width: 300px;
            height: 300px;
            background-color: thistle;
        }

        .active {
            font-size: 30px;
        }
    </style>
</head>

<body>
    <div id="app">
        <!-- <div v-if="false">{{msg}}</div>
        <div v-show="false">haha</div> -->
        <div :class="{demo:number>25?true:false}">
            today is monday
        </div>
        <button v-on:click="handleClick">点击</button>
        <!-- 另一种写法 -->
        <!-- <button @click="handleClick">点击</button> -->
    </div>
</body>

<script>
    let vm = {
        data () {
            return {
                msg: 'Gugua',
                bool: true,
                number: 18,
                box: 'demo'
            }
        },
        methods: {
            handleClick () {
                this.number++
            }
        }
    }
    Vue.createApp(vm).mount('#app')
</script>

</html>